package com.asiainfo.ssm.execute.util;


import org.apache.commons.lang.StringUtils;
import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;

import com.ai.appframe2.complex.tab.split.function.IFunction;
import com.asiainfo.commons.util.DateTimeUtil;

public class IDFunctionImpl implements IFunction {
	public static transient Log log = LogFactory.getLog(IDFunctionImpl.class);
	@Override
	public String convert(Object obj) throws Exception {
 		return (obj == null)? "": StringUtils.right(obj.toString(), 1); 
	}
	
	public static void main(String[] args) throws Exception{
		IDFunctionImpl impl = new IDFunctionImpl();
		System.out.println(impl.convert(1111));
		System.out.println(impl.convert(1112));
		System.out.println(impl.convert(1113));
		System.out.println(impl.convert(1114));
		System.out.println(impl.convert(1115));
		System.out.println(impl.convert("aaa"));
	}
}
